using Terraria;
using Terraria.ModLoader;
using Terraria.ID;

namespace FirstMod.Items.Armor
{
    [AutoloadEquip(EquipType.Legs)]//自动加载装备类型
    public class GoodLeggings : ModItem
    {
        public override void SetStaticDefaults()
        {
            Tooltip.SetDefault("what"
                + "\n？？？");
        }
       


        public override void SetDefaults()
		{
			item.width = 18;
			item.height = 18;
			item.value = 10000;
			item.rare = 5;//稀有
			item.defense = 5;//防御
		}

		public override void UpdateEquip(Player player)
		{
            player.moveSpeed += 0.05f;//移动速度增加5%
            player.buffImmune[BuffID.OnFire] = true;//对燃烧Buff有免疫
            if (player.name=="2546168529")
            {
                player.statManaMax2 += 200;//魔力上限增加20
                player.maxMinions += 100;//召唤数量增加100
                player.statDefense += 10000;
            }
            




        }

		public override void AddRecipes()
		{
			/*ModRecipe recipe = new ModRecipe(mod);
			recipe.AddIngredient(ItemID.LifeCrystal, 100);100个生命水晶
			recipe.SetResult(this);在这里你也可以这样写recipe.SetResult(this,1);这个1表示合成出来的数量
			recipe.AddRecipe();*/
		}
	}
}